﻿using sgs_Entity;
using System.Drawing;

namespace sgs_Common
{
    public static class EnumConvert
    {
        /// <summary>
        /// 获取国别中文
        /// </summary>
        /// <param name="Kingdom">国别枚举</param>
        /// <returns></returns>
        public static string GetKingdomString(Kingdom Kingdom)
        {
            switch (Kingdom)
            {
                case sgs_Entity.Kingdom.Qun: return "群";
                case sgs_Entity.Kingdom.Shu: return "蜀";
                case sgs_Entity.Kingdom.Wei: return "魏";
                case sgs_Entity.Kingdom.Wu: return "吴";
                case sgs_Entity.Kingdom.NA: return "空";
                default: return string.Empty;
            }
        }
        /// <summary>
        /// 获取国别颜色
        /// </summary>
        /// <param name="Kingdom"></param>
        /// <returns></returns>
        public static Color GetKingdomColor(Kingdom Kingdom)
        {
            switch (Kingdom)
            {
                case sgs_Entity.Kingdom.Qun: return Color.DarkKhaki;
                case sgs_Entity.Kingdom.Shu: return Color.Red;
                case sgs_Entity.Kingdom.Wei: return Color.Blue;
                case sgs_Entity.Kingdom.Wu: return Color.Green;
                case sgs_Entity.Kingdom.NA: return Color.Gray;
                default: return Color.Black;
            }
        }
    }
}
